#include<bits/stdc++.h>
using namespace std;
int bx, by, mx, my;
const int dx[] = {2, 1, -1, -2, -2, -1, 1, 2};
const int dy[] = {1, 2, 2, 1, -1, -2, -2, -1};
long long a[24][24];
bool valid(int x, int y) {
  return (x>=0&&y>=0&&x<=bx&&y<=by);
}
int main() {
  cin>>bx>>by>>mx>>my;
  if(valid(mx, my)) {
    a[mx][my] = -1;
  }
  for(int i=0; i<8; ++i) {
    int nx = mx+dx[i], ny = my+dy[i];
    if(valid(nx, ny)) {
      a[nx][ny] = -1;
    }
  }
  a[0][0] = 1;
  for(int i=0; i<=bx; i++) {
    for(int j=1; j<=by; j++) {
      if(a[i][j]!=-1) {
        if(i>0&&a[i-1][j]!=-1) {a[i][j]+=a[i-1][j];}
        if(a[i][j-1]!=-1) {a[i][j] += a[i][j-1];}
      }
    }
    a[i+1][0] += a[i][0];
  }
  cout<<a[bx][by]<<'\n';
}
